🎖️GitЯра🎖️
Node / meshtastic / Meshtastic-Android / files / feature / connections / src / commonMain / kotlin / org / meshtastic / feature / connections / ui / components / TransportFilterChips.kt
Displaying Raw • Download
feature/connections/src/commonMain/kotlin/org/meshtastic/feature/connections/ui/components/TransportFilterChips.kt renovate/actions-setup-java-5.x (f17e586c) Text, 3.34 KB
T8b949e/*
* Copyright (c) 2026 Meshtastic LLC
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <https://www.gnu.org/licenses/>.
*/
Tff7b72package T7ee787org.meshtastic.feature.connections.ui.components
Tff7b72import T7ee787androidx.compose.foundation.layout.Arrangement
Tff7b72import T7ee787androidx.compose.foundation.layout.Row
Tff7b72import T7ee787androidx.compose.foundation.layout.fillMaxWidth
Tff7b72import T7ee787androidx.compose.material3.FilterChip
Tff7b72import T7ee787androidx.compose.material3.Icon
Tff7b72import T7ee787androidx.compose.material3.Text
Tff7b72import T7ee787androidx.compose.runtime.Composable
Tff7b72import T7ee787androidx.compose.ui.Alignment
Tff7b72import T7ee787androidx.compose.ui.Modifier
Tff7b72import T7ee787androidx.compose.ui.graphics.vector.ImageVector
Tff7b72import T7ee787androidx.compose.ui.unit.dp
Tff7b72import T7ee787org.jetbrains.compose.resources.StringResource
Tff7b72import T7ee787org.jetbrains.compose.resources.stringResource
Tff7b72import T7ee787org.meshtastic.core.resources.Res
Tff7b72import T7ee787org.meshtastic.core.resources.transport_ble
Tff7b72import T7ee787org.meshtastic.core.resources.transport_tcp
Tff7b72import T7ee787org.meshtastic.core.resources.transport_usb
Tff7b72import T7ee787org.meshtastic.core.ui.icon.Bluetooth
Tff7b72import T7ee787org.meshtastic.core.ui.icon.MeshtasticIcons
Tff7b72import T7ee787org.meshtastic.core.ui.icon.Usb
Tff7b72import T7ee787org.meshtastic.core.ui.icon.Wifi
T8b949e/**
* Inclusive transport-visibility filter chips rendered below the connection card. Each chip independently toggles the
* visibility of its corresponding section ([showBle] → BLE, [showNetwork] → Network/TCP, [showUsb] → USB) in the device
* list. Selections are persisted by the caller (defaults to all-on).
*/
Tf0883e@Composable
Tff7b72fun Td2a8ffTransportFilterChipsTb4b4b4(
Te6edf3showBleTb4b4b4: Tffa657BooleanTb4b4b4,
Te6edf3showNetworkTb4b4b4: Tffa657BooleanTb4b4b4,
Te6edf3showUsbTb4b4b4: Tffa657BooleanTb4b4b4,
Te6edf3onToggleBleTb4b4b4: Tb4b4b4(Tb4b4b4) Tff7b72-Tff7b72> Tffa657UnitTb4b4b4,
Te6edf3onToggleNetworkTb4b4b4: Tb4b4b4(Tb4b4b4) Tff7b72-Tff7b72> Tffa657UnitTb4b4b4,
Te6edf3onToggleUsbTb4b4b4: Tb4b4b4(Tb4b4b4) Tff7b72-Tff7b72> Tffa657UnitTb4b4b4,
Te6edf3modifierTb4b4b4: Te6edf3Modifier Tff7b72= Te6edf3ModifierTb4b4b4,
Tb4b4b4) Tb4b4b4{
Te6edf3RowTb4b4b4(
Te6edf3modifier Tff7b72= Te6edf3modifierTb4b4b4.Te6edf3fillMaxWidthTb4b4b4(Tb4b4b4)Tb4b4b4,
Te6edf3horizontalArrangement Tff7b72= Te6edf3ArrangementTb4b4b4.Te6edf3spacedByTb4b4b4(T79c0ff8.Te6edf3dpTb4b4b4, Te6edf3AlignmentTb4b4b4.Te6edf3CenterHorizontallyTb4b4b4)Tb4b4b4,
Tb4b4b4) Tb4b4b4{
Te6edf3TransportChipTb4b4b4(
Te6edf3selected Tff7b72= Te6edf3showBleTb4b4b4,
Te6edf3label Tff7b72= Te6edf3ResTb4b4b4.Te6edf3stringTb4b4b4.Te6edf3transport_bleTb4b4b4,
Te6edf3icon Tff7b72= Te6edf3MeshtasticIconsTb4b4b4.Te6edf3BluetoothTb4b4b4,
Te6edf3onClick Tff7b72= Te6edf3onToggleBleTb4b4b4,
Tb4b4b4)
Te6edf3TransportChipTb4b4b4(
Te6edf3selected Tff7b72= Te6edf3showNetworkTb4b4b4,
Te6edf3label Tff7b72= Te6edf3ResTb4b4b4.Te6edf3stringTb4b4b4.Te6edf3transport_tcpTb4b4b4,
Te6edf3icon Tff7b72= Te6edf3MeshtasticIconsTb4b4b4.Te6edf3WifiTb4b4b4,
Te6edf3onClick Tff7b72= Te6edf3onToggleNetworkTb4b4b4,
Tb4b4b4)
Te6edf3TransportChipTb4b4b4(
Te6edf3selected Tff7b72= Te6edf3showUsbTb4b4b4,
Te6edf3label Tff7b72= Te6edf3ResTb4b4b4.Te6edf3stringTb4b4b4.Te6edf3transport_usbTb4b4b4,
Te6edf3icon Tff7b72= Te6edf3MeshtasticIconsTb4b4b4.Te6edf3UsbTb4b4b4,
Te6edf3onClick Tff7b72= Te6edf3onToggleUsbTb4b4b4,
Tb4b4b4)
Tb4b4b4}
Tb4b4b4}
Tf0883e@Composable
Tff7b72private Tff7b72fun Td2a8ffTransportChipTb4b4b4(Te6edf3selectedTb4b4b4: Tffa657BooleanTb4b4b4, Te6edf3labelTb4b4b4: Te6edf3StringResourceTb4b4b4, Te6edf3iconTb4b4b4: Te6edf3ImageVectorTb4b4b4, Te6edf3onClickTb4b4b4: Tb4b4b4(Tb4b4b4) Tff7b72-Tff7b72> Tffa657UnitTb4b4b4) Tb4b4b4{
Te6edf3FilterChipTb4b4b4(
Te6edf3selected Tff7b72= Te6edf3selectedTb4b4b4,
Te6edf3onClick Tff7b72= Te6edf3onClickTb4b4b4,
Te6edf3label Tff7b72= Tb4b4b4{ Te6edf3TextTb4b4b4(Te6edf3stringResourceTb4b4b4(Te6edf3labelTb4b4b4)Tb4b4b4) Tb4b4b4}Tb4b4b4,
Te6edf3leadingIcon Tff7b72= Tb4b4b4{ Te6edf3IconTb4b4b4(Te6edf3imageVector Tff7b72= Te6edf3iconTb4b4b4, Te6edf3contentDescription Tff7b72= Tff7b72nullTb4b4b4) Tb4b4b4}Tb4b4b4,
Tb4b4b4)
Tb4b4b4}
Served by rngit 1.5.0 - Generated in 0.05s